package com.um.springboot.starter.code;

import com.um.springboot.starter.utils.EnumUtil;
import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 通用返回码
 *
 * @author renjunwie
 * 日期 2022/7/26
 * 版权所有 广州优匠科技有限公司
 */
@Getter
@AllArgsConstructor
public enum CommonCode implements EnumUtil.ErrorEnum {

    Success(0, "操作成功!"),
    LoginExpired(10001, "登录已失效!"),
    Failed(10002, "操作失败!"),
    ServiceBusy(10003, "服务繁忙，请稍后再试！"),
    DeleteFailed(10004, "删除数据失败！"),
    UpdateError(10008, "上传文件错误！"),
    WriteFileError(10009, "写入文件错误！"),
    ConvEncodingError(10010, "文件名称name转utf-8编码出错！"),
    StreamError(10011, "获得文件输入流InputStream出错！"),
    CreateFileError(10012, "创建文件出错！"),
    CreateFolderError(10013, "创建目录出错或目录不存在！"),
    CreateThumbError(10016, "生成缩略图格式有误！"),
    ReadImsmanifestError(10017, "读取imsmanifest.xml文件错误！"),
    AccountDisabled(10018, "账号已停用！"),
    RSADecryptError(10019, "RSA解密错误！"),
    Base64DecryptError(10020, "Base64解密错误！"),
    ImportFileEmpty(10021, "导入文件为空！"),
    DataNotExist(10022, "数据不存在！"),
    NoDataPermission(10023, "没有数据访问权限！"),
    NoApiPermission(10024, "没有访问权限！"),
    NotOpen(10025, "未开放！"),
    ;

    private Integer code;
    private String msg;


}
